package com.migration.model.olddb;

import jakarta.persistence.*;
import lombok.Data;
import java.time.LocalDateTime;
import java.io.Serializable;

/**
 * 知识库详情信息表 实体类
 * 表名：ra_knowledge_detail
 * 自动生成的实体类
 */
@Data
@Entity
@Table(name = "ra_knowledge_detail")
public class RaKnowledgeDetail implements Serializable {

    private static final long serialVersionUID = 1L;
    
    /**
     * 主键
     * 主键
     */
    @Id
    @Column(name = "id", nullable = false)
    private Long id;
    
    /**
     * 知识库主键
     */
    @Column(name = "knowledge_id", nullable = false)
    private Long knowledgeId;
    
    /**
     * 设备类型主键
     */
    @Column(name = "equip_id", nullable = false)
    private Long equipId;
    
    /**
     * 设备类型名称
     */
    @Column(name = "equip_name", nullable = false, length = 128)
    private String equipName;
    
    /**
     * 偏离主键
     */
    @Column(name = "deviate_id")
    private Long deviateId;
    
    /**
     * 偏离名称
     */
    @Column(name = "deviate_name", length = 128)
    private String deviateName;
    
    /**
     * 知识库类型
     */
    @Column(name = "knowledge_type", nullable = false)
    private Byte knowledgeType;
    
    /**
     * 知识库描述
     */
    @Column(name = "knowledge_desc", nullable = false, length = 512)
    private String knowledgeDesc;
    
    /**
     * 知识库数据类型
     */
    @Column(name = "data_type")
    private Byte dataType;
    
    /**
     * 扩展JSON
     */
    @Column(name = "extend_json", length = 65535)
    private String extendJson;
    
    /**
     * 是否删除（0、否1、是）
     * 默认值: 0
     */
    @Column(name = "is_del", nullable = false)
    private Byte isDel;
    
    /**
     * 创建时间
     * 默认值: CURRENT_TIMESTAMP
     */
    @Column(name = "create_time", nullable = false)
    private java.time.LocalDateTime createTime;
    
    /**
     * 创建者
     */
    @Column(name = "create_by", length = 64)
    private String createBy;
    
    /**
     * 更新时间
     * 默认值: CURRENT_TIMESTAMP
     */
    @Column(name = "update_time", nullable = false)
    private java.time.LocalDateTime updateTime;
    
    /**
     * 更新者
     */
    @Column(name = "update_by", length = 64)
    private String updateBy;
    
    @Override
    public String toString() {
        return "RaKnowledgeDetail{" +
            "id=" + id +
            ", knowledgeId=" + knowledgeId +
            ", equipId=" + equipId +
            ", equipName=" + equipName +
            ", deviateId=" + deviateId +
            ", deviateName=" + deviateName +
            ", knowledgeType=" + knowledgeType +
            ", knowledgeDesc=" + knowledgeDesc +
            ", dataType=" + dataType +
            ", extendJson=" + extendJson +
            ", isDel=" + isDel +
            ", createTime=" + createTime +
            ", createBy=" + createBy +
            ", updateTime=" + updateTime +
            ", updateBy=" + updateBy +
        '}';
    }
} 